package com.changpay.zywy.mvp.presenter

import com.changpay.zywy.base.BasePresenter
import com.changpay.zywy.ext.ss
import com.changpay.zywy.mvp.contract.TodayTradContract
import com.changpay.zywy.mvp.model.TodayTradModel


/**
 * Created by chenxz on 2018/5/27.
 */
class TodayTradPresenter : BasePresenter<TodayTradContract.Model, TodayTradContract.View>(), TodayTradContract.Presenter {
    override fun getTodayInfo(map: MutableMap<String, String>) {
        mModel?.getTodayInfo(map)?.ss(mModel, mView) {
            mView?.ShowTodayInfo(it.result)
        }
    }

    override fun getTodayList(map: MutableMap<String, String>) {
        mModel?.getTodayList(map)?.ss(mModel, mView) {
            mView?.ShowTodayList(it.result)
        }
    }

    override fun createModel(): TodayTradContract.Model? = TodayTradModel()

}